# 利用python定制类写一个链式调用类：__str__方法和__getattr__的应用
# e.g.
class Chain:

    def __init__(self, item=''):
        self._item = item

    def __getattr__(self, item):
        return Chain('%s/%s' % (self._item, item))

    def __str__(self):
        return self._item


print(Chain().status.user.timeline.list)
